//
//  GWMySearchBar.m
//  新浪微博
//
//  Created by qianfeng on 16/1/9.
//  Copyright (c) 2016年 高炜. All rights reserved.
//

#import "GWMySearchBar.h"

@implementation GWMySearchBar
+(GWMySearchBar *)searchBar
{
    GWMySearchBar *textField =[[GWMySearchBar alloc]init];
    UIImageView *search =[[UIImageView alloc]initWithImage:[UIImage imageWithName:@"tabbar_discover"]];
    search.size =CGSizeMake([UIImage imageWithName:@"tabbar_discover"].size.width+6, 30);
    search.contentMode =UIViewContentModeCenter;
    textField.background =[UIImage reSizeWithName:@"searchbar_textfield_background"];
    textField.leftView =search;
    textField.leftViewMode =UITextFieldViewModeAlways;
    textField.clearButtonMode =UITextFieldViewModeAlways;
    return textField;
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
